package com.lyc.wanandroid_kotlin.ui.activity.login.mvp.contract

import com.lyc.wanandroid_kotlin.base.IModel
import com.lyc.wanandroid_kotlin.base.IPresenter
import com.lyc.wanandroid_kotlin.base.IView
import com.lyc.wanandroid_kotlin.bean.HttpResult
import com.lyc.wanandroid_kotlin.bean.LoginData
import io.reactivex.Observable

/**
 * ClassName:com.lyc.wanandroid_kotlin.ui.activity.login.mvp.contract
 * Description:
 */
interface RegisterContract {

    interface View : IView {
        fun registerSuccess(data: LoginData)

        fun registerFail()
    }

    interface Presenter : IPresenter<View> {
        fun registerWanAndroid(username: String, password: String, repassword: String)
    }

    interface Model : IModel {
        fun registerWanAndroid(
            username: String,
            password: String,
            repassword: String
        ): Observable<HttpResult<LoginData>>
    }
}